import org.junit.Test

class FunctionTest {

    @Test
    fun test() {
        println(num1AndNum2(1, 2) { x, y ->
            x - y
        })
    }
}

fun num1AndNum2(x: Int, y: Int, operate: (Int, Int) -> Int): Int {
    return operate.invoke(x, y)
}